package com.itheima.canal.utils;

import com.alibaba.otter.canal.protocol.CanalEntry;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

public class CanalUtils {
    public static Map<String,String> column2Map(List<CanalEntry.Column> columns) {
        Map<String, String> map = new HashMap<>();
        columns.forEach(c->map.put(c.getName(),c.getValue()));
        return map;
    }
}
